package cytargetlinker.conversion.data;

import cytargetlinker.conversion.graph.Graph;
import cytargetlinker.conversion.graph.Graph.Edge;

public class DrugTargetInteraction {
	private INode source;
	private INode target;
	private String interactionClass = "TF-target";
	
	public DrugTargetInteraction(INode source, INode target) {
		this.source = source;
		this.target = target;
	}
	
	public Edge createEdge(Graph graph, String datasource, int count) {
		Edge e = graph.addEdge("" + count, getSource().getNode(graph), getTarget().getNode(graph));
		e.setAttribute("interactionType", getInteractionClass());
		e.setAttribute("datasource", datasource);
		return e;
	}

	public String getInteractionClass() {
		return interactionClass;
	}

	public INode getSource() {
		return source;
	}

	public INode getTarget() {
		return target;
	}
}
